<template>
  <div class="app-container">
    <p>收卖数据报表</p>
    <div class="header ">
      <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px"
        class="">
        <el-form-item label="选择时间" prop="orderDate">
          <el-date-picker v-model="queryParams.orderDate" @change="changeTime" type="daterange" align="right"
            start-placeholder="开始日期" end-placeholder="结束日期">
          </el-date-picker>
        </el-form-item>

        <el-form-item>
          <el-button size="mini" @click="resetQuery">重置</el-button>
          <el-button type="primary" size="mini" @click="handleQuery">筛选</el-button>
          <el-button type="primary" plain size="mini" @click="handleLoadNew">刷新</el-button>
        </el-form-item>
      </el-form>

    </div>
    <el-row :gutter="20" style="margin-top: 22px;">
      <el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="card-box">
        <el-row :gutter="20" >

<el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="card-box">

  <div class="">
    <div class="header">
      <el-row :gutter="20" class="flex1 container-xiao">
        <el-col :xs="12" :sm="24" :md="24" :lg="12" :xl="12">
          <el-progress type="circle" :percentage="80" :stroke-width="8" :format="format" :color="colors" :width="84">
          </el-progress>
        </el-col>
        <el-col :xs="12" :sm="24" :md="24" :lg="12" :xl="12">
          <div class="paymount">
            <span style="font-size: 24px;font-weight: 600;">￥2000.00</span>
            <span style="font-size: 14px;color: #BCC3D4;padding-top: 8px;">今日销售金额</span>
          </div>
        </el-col>
      </el-row>
    </div>
  </div>
</el-col>
<el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="card-box">
  <div class="grid-content bg-purple">
    <div class="header">
      <el-row :gutter="20" class="flex1 container-xiao">
        <el-col :xs="12" :sm="24" :md="24" :lg="12" :xl="12">
          <el-progress type="circle" :percentage="80" :stroke-width="8" :format="format1" :color="colors1" :width="84">
          </el-progress>
        </el-col>
        <el-col :xs="12" :sm="24" :md="24" :lg="12" :xl="12">
          <div class="paymount">
            <span style="font-size: 24px;font-weight: 600;">￥2000.00</span>
            <span style="font-size: 14px;color: #BCC3D4;padding-top: 8px;">昨日销售金额</span>
          </div>
        </el-col>
      </el-row>
    </div>
  </div>
</el-col>

</el-row>
<el-row :gutter="20" >
  <el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="card-box">
  <div class="grid-content bg-purple">
    <div class="header">
      <el-row :gutter="20" class="flex1 container-xiao">
        <el-col :xs="12" :sm="24" :md="24" :lg="12" :xl="12">
          <el-progress type="circle" :percentage="80" :stroke-width="8" :format="format2" :color="colors2" :width="84">
          </el-progress>
        </el-col>
        <el-col :xs="12" :sm="24" :md="24" :lg="12" :xl="12">
          <div class="paymount">
            <span style="font-size: 24px;font-weight: 600;">￥2000.00</span>
            <span style="font-size: 14px;color: #BCC3D4;padding-top: 8px;">近三日销售金额</span>
          </div>
        </el-col>
      </el-row>
    </div>
  </div>
</el-col>
<el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="card-box">
  <div class="grid-content bg-purple">
    <div class="header">
      <el-row :gutter="20" class="flex1 container-xiao">
        <el-col :xs="12" :sm="24" :md="24" :lg="12" :xl="12">
          <el-progress type="circle" :percentage="80" :stroke-width ="8" :format="format3" :color="colors3" :width="84">
          </el-progress>
        </el-col>
        <el-col :xs="12" :sm="24" :md="24" :lg="12" :xl="12">
          <div class="paymount">
            <span style="font-size: 24px;font-weight: 600;">￥2000.00</span>
            <span style="font-size: 14px;color: #BCC3D4;padding-top: 8px;">总成交金额</span>
          </div>
        </el-col>
      </el-row>
    </div>
  </div>
</el-col>
</el-row>
      </el-col>
      <el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="card-box">
        <div class="header">
          <div class="txt-bor flex4">
            <p>近7日销售看板</p>
            <!-- <span style="font-size: 24px;font-weight: 600;">￥15457747</span> -->
          </div>
          <div>
            <div style="display: flex;align-items: center;">
              <span class="consad">2023/9/8 星期一</span>
              <el-progress :text-inside="true" :stroke-width="26" :format="format4" :percentage="100"
              style="margin-top: 12px;color: #fff !important !important;width:70%;"></el-progress>
            </div>
            <div style="display: flex;align-items: center;">
              <span class="consad">2023/9/8 星期一</span>
              <el-progress :text-inside="true" :stroke-width="26" :format="format4" :percentage="60"
              style="margin-top: 12px;color: #fff !important !important;width:70%;"></el-progress>
            </div>
            <div style="display: flex;align-items: center;">
              <span class="consad">2023/9/10 星期三</span>
              <el-progress :text-inside="true" :stroke-width="26" :format="format4" :percentage="100"
              style="margin-top: 12px;color: #fff !important !important;width:70%;"></el-progress>
            </div>
            <div style="display: flex;align-items: center;">
              <span class="consad">2023/9/10 星期三</span>
              <el-progress :text-inside="true" :stroke-width="26" :format="format4" :percentage="100"
              style="margin-top: 12px;color: #fff !important !important;width:70%;"></el-progress>
            </div>
            <div style="display: flex;align-items: center;">
              <span class="consad">2023/9/10 星期三</span>
              <el-progress :text-inside="true" :stroke-width="26" :format="format4" :percentage="80"
              style="margin-top: 12px;color: #fff !important !important;width:70%;"></el-progress>
            </div>
            <div style="display: flex;align-items: center;">
              <span class="consad">2023/9/10 星期三</span>
              <el-progress :text-inside="true" :stroke-width="26" :format="format4" :percentage="70"
              style="margin-top: 12px;color: #fff !important !important;width:70%;"></el-progress>
            </div>
            <div style="display: flex;align-items: center;">
              <span class="consad">2023/9/10 星期三</span>
              <el-progress :text-inside="true" :stroke-width="26" :format="format4" :percentage="70"
              style="margin-top: 12px;color: #fff !important !important;width:70%;margin-bottom:12px"></el-progress>
            </div>


          </div>
        </div>

      </el-col>
    </el-row>


    <overView></overView>
    <!-- <el-row :gutter="20">
      <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8">
        <div class="header">
          <div class="txt-bor flex4">
            <p>号库总览</p>
          <span style="font-size: 24px;font-weight: 600;">2662个</span>
          </div>
          <div>
            <el-progress :text-inside="true" :stroke-width="26"  :format="format" :percentage="70" style="margin-top: 16px;"></el-progress>
            <el-progress :text-inside="true" :stroke-width="26" :percentage="70" style="margin-top: 11px;"></el-progress>
            <el-progress :text-inside="true" :stroke-width="26" :percentage="70" style="margin-top: 11px;margin-bottom: 15px;"></el-progress>
          </div>
        </div>
      </el-col>
      <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8"></el-col>
      <el-col :xs="24" :sm="8" :md="8" :lg="8" :xl="8"></el-col>
    </el-row> -->
  </div>
</template>

<script>
import overView from './components/overView.vue'
export default {
  components:{overView},
  data() {
    return {
      //状态数据
      TodayCount: '',
      queryParams: {
        orderDate: [],
      },
      // 显示搜索条件
      showSearch: true,
      status: {},
      colors: [
        { color: '#563BFF', percentage: 20 },
      ],
      colors1: [
        { color: '#FF7049', percentage: 20 },
      ],
      colors2: [
        { color: '#499DFF', percentage: 20 },
      ],
      colors3: [
        { color: '#8C35FF', percentage: 20 },
      ]
    }

  },

  methods: {
    format(percentage) {
      return "今日"
    },
    format1(percentage) {
      return "昨日"
    },
    format2(percentage) {
      return "三日"
    },
    format3(percentage) {
      return "总成交"
    },
    format4(percentage) {
      return "当日销售：124单，销售额：￥1456144.41"
    },
    format5(percentage) {
      return "穿越火线：￥554124"
    },
    format6(percentage) {
      return "QQ飞车：￥156414"
    },
    format7(percentage) {
      return "原神：￥151344"
    },
    /** 搜索按钮操作 */
    handleQuery() {
      this.queryParams.pageNum = 1;
      this.getList();
    },
    /** 重置按钮操作 */
    resetQuery() {
      this.resetForm("queryForm");
      this.handleQuery();
    },
    handleLoadNew() {

    },
    changeTime(value) {
      if (value && value.length === 2) {
        // value[0] 和 value[1] 分别是开始和结束日期的 Date 对象
        let startDate = this.formatDate(value[0]);
        let endDate = this.formatDate(value[1]);
        this.queryParams.startDate = startDate
        this.queryParams.endDate = endDate
        this.getList()
      }
    },
  }

}
</script>

<style lang="scss" scoped>
// /deep/ .el-progress-circle__track {
// stroke: #EEEEEE;
// }
.consad{
  color: #555770;
  font-size: 12px;
  width: 105px;
  padding-top: 15px;
}
::v-deep .el-progress-bar__outer {
  background-color: #fff !important;
}

::v-deep .el-progress-bar__inner {
  text-align: left;
  background: linear-gradient(268.09deg, #6067FA 0%, #7799FC 100%)
}

::v-deep .el-progress-bar__innerText {
  color: #FFFFFF !important;
  font-size: 12px !important;
  font-weight: 600;
  padding-left: 16px;
}s
::v-deep .el-progress-circle__track {
  stroke: #F7F8FB;
}
::v-deep .el-progress-bar__inner{
  text-align: left;
}
// ::v-deep .el-progress__text {
//   color: #563BFF !important;
//   font-size: 12px !important;
//   font-weight: 600;
// }
.txt-bor {
  >p {

    opacity: 1;
    margin: 0 0 0 20px;
    /** 文本1 */
    font-size: 18px;
    font-weight: 400;
    color: rgba(17, 38, 60, 1);
    border-left: 3px solid rgba(84, 91, 245, 1);
    padding-left: 10px;
    // margin-bottom: 15px;
    margin-left: 0;
  }
}

.header {
  min-height: 55px;
  opacity: 1;
  border-radius: 10px;
  background: rgba(255, 255, 255, 1);
  box-shadow: 0px 20px 45px rgba(240, 237, 246, 0.5);
  margin-bottom: 10px;
  padding: 10px 20px;
  padding-top: 16px;
  >p {

    opacity: 1;
    margin: 0 0 0 20px;
    /** 文本1 */
    font-size: 18px;
    font-weight: 400;
    color: rgba(17, 38, 60, 1);
    border-left: 3px solid rgba(84, 91, 245, 1);
    padding-left: 10px;
    // margin-bottom: 15px;
    margin-left: 0;
  }

  .images {
    display: flex;
    justify-content: space-between;
    padding: 0 6.25rem;
    margin-top: 15px;
    .item {
      text-align: center;

      p {
        margin-top:0px;
        opacity: 1;
        font-size: 16px;
        font-weight: 400;
        letter-spacing: 0px;
        padding-top: .5625rem;
        color: rgba(156, 159, 167, 1);
        text-align: center;
        vertical-align: top;
      }

      h1 {

        font-size: 30px;
        margin: 8px;
      }
    }
  }



}
.app-container {
  >p {
    opacity: 1;
    margin: 0 0 0 20px;
    /** 文本1 */
    font-size: 18px;
    font-weight: 400;
    color: rgba(17, 38, 60, 1);
    border-left: 3px solid rgba(84, 91, 245, 1);
    padding-left: 10px;
    margin-bottom: 15px;
    margin-left: 0;
  }
  .header2{
    min-height: 55px;
  opacity: 1;
  border-radius: 10px;
  background: rgba(255, 255, 255, 1);
  box-shadow: 0px 20px 45px rgba(240, 237, 246, 0.5);
  margin-bottom: 10px;
  padding: 10px 20px;
  padding-top: 16px;
  }
  .header {

    .el-form {
      left: 224px;
      top: 104px;
      min-height: 55px;
      opacity: 1;
      border-radius: 10px;
      background: rgba(255, 255, 255, 1);
      box-shadow: 0px 20px 45px rgba(240, 237, 246, 0.5);
      margin-bottom: 15px;
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      padding: 0 20px;
      padding-top: 10px;
      padding-bottom: 5px;

      .el-form-item {
        margin-bottom: 10px;

        ::v-deep .el-form-item__label {
          opacity: 1;
          /** 文本1 */
          font-size: 14px;
          font-weight: 400;
          letter-spacing: -0.07px;
          line-height: 32px;
          color: rgba(3, 2, 2, 1);
          text-align: right;
          vertical-align: middle;

        }

        ::v-deep .el-form-item__content {

          .el-input {
            width: 165px;

            .el-input__inner {
              width: 165px;
              border: 1px solid rgba(127, 127, 213, 0.5);
              border-radius: 10px;
            }
          }

          .el-button {
            height: 32px;
            opacity: 1;
            border-radius: 2px;
            background: linear-gradient(268.09deg, rgba(96, 103, 250, 1) 0%, rgba(119, 153, 252, 1) 100%);
            padding: 8px 18px;
            color: #fff;
            border: none;
            margin-left: 25px;

            &:hover {
              border: none;
              background: linear-gradient(268.09deg, rgb(69, 78, 255) 0%, rgb(88, 130, 255) 100%);

            }

            &:nth-child(1) {
              width: 60px;
              height: 32px;
              opacity: 1;
              border-radius: 2px;
              background: rgba(242, 243, 245, 1);
              color: rgba(0, 0, 0, 0.3);
              padding: 8px 16px 8px 16px;

              &:hover {
                border: none;
                background: rgb(228, 228, 228);

              }
            }


          }
        }


      }
    }
  }
}

.paymount {
  margin: auto;
  display: flex;
  align-items: flex-end;
  flex-direction: column;

}

.flex1 {
  display: flex;
  justify-content: center;
  align-items: center;
}
.flex2{
  display: flex;
  align-items: center;
}
.flex3{
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.flex4{
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.dealday{
  padding-left: 1.1875rem;
}
.colorcount{
  font-weight: 600;
  font-size: 16px;
  background-image:-webkit-linear-gradient(right,#8486F8,#FFA6DB);
    -webkit-background-clip:text;
    -webkit-text-fill-color:transparent;
}
.colorcount1{
  font-weight: 600;
  font-size: 16px;
  background-image:-webkit-linear-gradient(right,#5F82F5,#D6ABFF);
    -webkit-background-clip:text;
    -webkit-text-fill-color:transparent;
}
.colorcount2{
  font-weight: 600;
  font-size: 16px;
  background-image:-webkit-linear-gradient(right,#2BE0D4,#70D1FA);
    -webkit-background-clip:text;
    -webkit-text-fill-color:transparent;
}
.boxdelmg{
  width: 48px;
  height: 48px;
  background-color: #EEF2FD;
  border-radius: 6px;
  >img{
    width:23.3px;
    height: 29.8px;
  }
}
.boxdelmg1{
  width: 48px;
  height: 48px;
  background-color: #F4EDFC;
  border-radius: 6px;
  >img{
    width:26.4px;
    height:26.4px;
  }
}
.boxdelmg2{
  width: 48px;
  height: 48px;
  background-color: #EDFBFC;
  border-radius: 6px;
  >img{
    width:26.4px;
    height:26.4px;
  }
}
.container-xiao {
  margin-top: 12px;
  padding: 0 1.25rem;
  padding-bottom: 20px;
  padding-top: 8px;
}
.textgray{
  color: #BCC3D4;
  font-size: 14px;
  padding-top: 4px;
}
.contane-bixo{
  margin-bottom:20px;
}
</style>
